<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
  <title>std.date</title>
  <link href="./css/style.css" rel="stylesheet" type="text/css"/>
  <!-- <link href="./img/icon.png" rel="icon" type="image/png"/> -->
  <script type="text/javascript" src="./js/jquery.js"></script>
  <script type="text/javascript" src="./js/modules.js"></script>
  <script type="text/javascript" src="./js/quicksearch.js"></script>
  <script type="text/javascript" src="./js/navigation.js"></script>
  <!--<script type="text/javascript" src="./js/jquery.treeview.js"></script>-->
  <script type="text/javascript">
    var g_moduleFQN = "std.date";
  </script>
  
</head>
<body>
<div id="content">
  <h1><a href="./htmlsrc/std.date.html" class="symbol">std.date</a></h1>
  
<div class="summary">Dates are represented in several formats. The date implementation revolves
 around a central type, d_time, from which other formats are converted to and
 from.
 Dates are calculated using the Gregorian calendar.</div>
<p class="sec_header">References:</p><a href="http://en.wikipedia.org/wiki/Gregorian_calendar">Gregorian calendar (Wikipedia)</a>
<dl>
<dt class="decl">alias long <a class="symbol _alias" name="d_time" href="./htmlsrc/std.date.html#L36" kind="alias" beg="36" end="36">d_time</a>; <a title="Permalink to this symbol" href="#d_time" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L36">#</a></dt>
<dd class="ddef">
<div class="summary">d_time is a signed arithmetic type giving the time elapsed since January 1,
 1970.
 Negative values are for dates preceding 1970. The time unit used is Ticks.
 Ticks are milliseconds or smaller intervals.</div>
The usual arithmetic operations can be performed on d_time, such as adding,
 subtracting, etc. Elapsed time in Ticks can be computed by subtracting a
 starting d_time from an ending d_time.</dd>
<dt class="decl">d_time <a class="symbol _variable" name="d_time_nan" href="./htmlsrc/std.date.html#L41" kind="variable" beg="41" end="41">d_time_nan</a>; <span class="attrs">[<span class="stc">const</span>]</span> <a title="Permalink to this symbol" href="#d_time_nan" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L41">#</a></dt>
<dd class="ddef">
<div class="summary">A value for d_time that does not represent a valid time.</div></dd>
<dt class="decl">struct <a class="symbol _struct" name="Date" href="./htmlsrc/std.date.html#L46" kind="struct" beg="46" end="65">Date</a>; <a title="Permalink to this symbol" href="#Date" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L46">#</a></dt>
<dd class="ddef">
<div class="summary">Time broken down into its components.</div>
<dl>
<dt class="decl">int <a class="symbol _variable" name="Date.year" href="./htmlsrc/std.date.html#L48" kind="variable" beg="48" end="48">year</a>; <a title="Permalink to this symbol" href="#Date.year" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L48">#</a></dt>
<dd class="ddef">
<div class="summary">use int.min as "nan" year value</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.month" href="./htmlsrc/std.date.html#L49" kind="variable" beg="49" end="49">month</a>; <a title="Permalink to this symbol" href="#Date.month" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L49">#</a></dt>
<dd class="ddef">
<div class="summary">1..12</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.day" href="./htmlsrc/std.date.html#L50" kind="variable" beg="50" end="50">day</a>; <a title="Permalink to this symbol" href="#Date.day" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L50">#</a></dt>
<dd class="ddef">
<div class="summary">1..31</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.hour" href="./htmlsrc/std.date.html#L51" kind="variable" beg="51" end="51">hour</a>; <a title="Permalink to this symbol" href="#Date.hour" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L51">#</a></dt>
<dd class="ddef">
<div class="summary">0..23</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.minute" href="./htmlsrc/std.date.html#L52" kind="variable" beg="52" end="52">minute</a>; <a title="Permalink to this symbol" href="#Date.minute" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L52">#</a></dt>
<dd class="ddef">
<div class="summary">0..59</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.second" href="./htmlsrc/std.date.html#L53" kind="variable" beg="53" end="53">second</a>; <a title="Permalink to this symbol" href="#Date.second" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L53">#</a></dt>
<dd class="ddef">
<div class="summary">0..59</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.ms" href="./htmlsrc/std.date.html#L54" kind="variable" beg="54" end="54">ms</a>; <a title="Permalink to this symbol" href="#Date.ms" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L54">#</a></dt>
<dd class="ddef">
<div class="summary">0..999</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.weekday" href="./htmlsrc/std.date.html#L55" kind="variable" beg="55" end="55">weekday</a>; <a title="Permalink to this symbol" href="#Date.weekday" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L55">#</a></dt>
<dd class="ddef">
<div class="summary">0: not specified, 1..7: Sunday..Saturday</div></dd>
<dt class="decl">int <a class="symbol _variable" name="Date.tzcorrection" href="./htmlsrc/std.date.html#L56" kind="variable" beg="56" end="56">tzcorrection</a>; <a title="Permalink to this symbol" href="#Date.tzcorrection" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L56">#</a></dt>
<dd class="ddef">
<div class="summary">-1200..1200 correction in hours</div></dd>
<dt class="decl">void <a class="symbol _function" name="Date.parse" href="./htmlsrc/std.date.html#L59" kind="function" beg="59" end="64">parse</a><span class="params">(string <em>s</em>)</span>; <a title="Permalink to this symbol" href="#Date.parse" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L59">#</a></dt>
<dd class="ddef">
<div class="summary">Parse date out of string s[] and store it in this Date instance.</div></dd></dl></dd>
<dt class="decl"><a class="symbol _enum" name="enum" href="./htmlsrc/std.date.html#L67" kind="enum" beg="67" end="79">enum</a>; <a title="Permalink to this symbol" href="#enum" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L67">#</a></dt>
<dd class="ddef">
<dl>
<dt class="decl"><a class="symbol _enummem" name="enum.HoursPerDay" href="./htmlsrc/std.date.html#L69" kind="enummem" beg="69" end="69">HoursPerDay</a> <a title="Permalink to this symbol" href="#enum.HoursPerDay" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L69">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.MinutesPerHour" href="./htmlsrc/std.date.html#L70" kind="enummem" beg="70" end="70">MinutesPerHour</a> <a title="Permalink to this symbol" href="#enum.MinutesPerHour" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L70">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.msPerMinute" href="./htmlsrc/std.date.html#L71" kind="enummem" beg="71" end="71">msPerMinute</a> <a title="Permalink to this symbol" href="#enum.msPerMinute" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L71">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.msPerHour" href="./htmlsrc/std.date.html#L72" kind="enummem" beg="72" end="72">msPerHour</a> <a title="Permalink to this symbol" href="#enum.msPerHour" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L72">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.msPerDay" href="./htmlsrc/std.date.html#L73" kind="enummem" beg="73" end="73">msPerDay</a> <a title="Permalink to this symbol" href="#enum.msPerDay" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L73">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.TicksPerMs" href="./htmlsrc/std.date.html#L74" kind="enummem" beg="74" end="74">TicksPerMs</a> <a title="Permalink to this symbol" href="#enum.TicksPerMs" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L74">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.TicksPerSecond" href="./htmlsrc/std.date.html#L75" kind="enummem" beg="75" end="75">TicksPerSecond</a> <a title="Permalink to this symbol" href="#enum.TicksPerSecond" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L75">#</a></dt>
<dd class="ddef">
<div class="summary">Will be at least 1000</div></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.TicksPerMinute" href="./htmlsrc/std.date.html#L76" kind="enummem" beg="76" end="76">TicksPerMinute</a> <a title="Permalink to this symbol" href="#enum.TicksPerMinute" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L76">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.TicksPerHour" href="./htmlsrc/std.date.html#L77" kind="enummem" beg="77" end="77">TicksPerHour</a> <a title="Permalink to this symbol" href="#enum.TicksPerHour" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L77">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl"><a class="symbol _enummem" name="enum.TicksPerDay" href="./htmlsrc/std.date.html#L78" kind="enummem" beg="78" end="78">TicksPerDay</a> <a title="Permalink to this symbol" href="#enum.TicksPerDay" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L78">#</a></dt>
<dd class="ddef"></dd></dl></dd>
<dt class="decl">d_time <a class="symbol _variable" name="LocalTZA" href="./htmlsrc/std.date.html#L81" kind="variable" beg="81" end="81">LocalTZA</a>; <a title="Permalink to this symbol" href="#LocalTZA" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L81">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">char[] <a class="symbol _variable" name="daystr" href="./htmlsrc/std.date.html#L83" kind="variable" beg="83" end="83">daystr</a>; <span class="attrs">[<span class="stc">invariant</span>]</span> <a title="Permalink to this symbol" href="#daystr" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L83">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">char[] <a class="symbol _variable" name="monstr" href="./htmlsrc/std.date.html#L84" kind="variable" beg="84" end="84">monstr</a>; <span class="attrs">[<span class="stc">invariant</span>]</span> <a title="Permalink to this symbol" href="#monstr" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L84">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int[12] <a class="symbol _variable" name="mdays" href="./htmlsrc/std.date.html#L86" kind="variable" beg="86" end="86">mdays</a>; <span class="attrs">[<span class="stc">const</span>]</span> <a title="Permalink to this symbol" href="#mdays" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L86">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">void <a class="symbol _function" name="toISO8601YearWeek" href="./htmlsrc/std.date.html#L95" kind="function" beg="95" end="147">toISO8601YearWeek</a><span class="params">(d_time <em>t</em>, out int <em>year</em>, out int <em>week</em>)</span>; <a title="Permalink to this symbol" href="#toISO8601YearWeek" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L95">#</a></dt>
<dd class="ddef">
<div class="summary">Compute year and week [1..53] from t. The ISO 8601 week 1 is the first week
 of the year that includes January 4. Monday is the first day of the week.</div>
<p class="sec_header">References:</p><a href="http://en.wikipedia.org/wiki/ISO_8601">ISO 8601 (Wikipedia)</a></dd>
<dt class="decl">d_time <a class="symbol _function" name="floor" href="./htmlsrc/std.date.html#L153" kind="function" beg="153" end="158">floor</a><span class="params">(d_time <em>d</em>, int <em>divisor</em>)</span>; <a title="Permalink to this symbol" href="#floor" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L153">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="dmod" href="./htmlsrc/std.date.html#L160" kind="function" beg="160" end="168">dmod</a><span class="params">(d_time <em>n</em>, d_time <em>d</em>)</span>; <a title="Permalink to this symbol" href="#dmod" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L160">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="HourFromTime" href="./htmlsrc/std.date.html#L170" kind="function" beg="170" end="173">HourFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#HourFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L170">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="MinFromTime" href="./htmlsrc/std.date.html#L175" kind="function" beg="175" end="178">MinFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#MinFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L175">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="SecFromTime" href="./htmlsrc/std.date.html#L180" kind="function" beg="180" end="183">SecFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#SecFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L180">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="msFromTime" href="./htmlsrc/std.date.html#L185" kind="function" beg="185" end="188">msFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#msFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L185">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="TimeWithinDay" href="./htmlsrc/std.date.html#L190" kind="function" beg="190" end="193">TimeWithinDay</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#TimeWithinDay" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L190">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="toInteger" href="./htmlsrc/std.date.html#L195" kind="function" beg="195" end="198">toInteger</a><span class="params">(d_time <em>n</em>)</span>; <a title="Permalink to this symbol" href="#toInteger" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L195">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="Day" href="./htmlsrc/std.date.html#L200" kind="function" beg="200" end="203">Day</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#Day" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L200">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="LeapYear" href="./htmlsrc/std.date.html#L205" kind="function" beg="205" end="209">LeapYear</a><span class="params">(int <em>y</em>)</span>; <a title="Permalink to this symbol" href="#LeapYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L205">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="DaysInYear" href="./htmlsrc/std.date.html#L211" kind="function" beg="211" end="214">DaysInYear</a><span class="params">(int <em>y</em>)</span>; <a title="Permalink to this symbol" href="#DaysInYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L211">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="DayFromYear" href="./htmlsrc/std.date.html#L216" kind="function" beg="216" end="222">DayFromYear</a><span class="params">(int <em>y</em>)</span>; <a title="Permalink to this symbol" href="#DayFromYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L216">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="TimeFromYear" href="./htmlsrc/std.date.html#L224" kind="function" beg="224" end="227">TimeFromYear</a><span class="params">(int <em>y</em>)</span>; <a title="Permalink to this symbol" href="#TimeFromYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L224">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="YearFromTime" href="./htmlsrc/std.date.html#L233" kind="function" beg="233" end="258">YearFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#YearFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L233">#</a></dt>
<dd class="ddef">
<div class="summary">Calculates the year from the d_time t.</div></dd>
<dt class="decl">int <a class="symbol _function" name="inLeapYear" href="./htmlsrc/std.date.html#L272" kind="function" beg="272" end="275">inLeapYear</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#inLeapYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L272">#</a></dt>
<dd class="ddef">
<div class="summary">Determines if d_time t is a leap year.</div>
A leap year is every 4 years except years ending in 00 that are not
 divsible by 400.
<p class="sec_header">Returns:</p>!=0 if it is a leap year.
<p class="sec_header">References:</p><a href="http://en.wikipedia.org/wiki/Leap_year">Wikipedia</a></dd>
<dt class="decl">int <a class="symbol _function" name="MonthFromTime" href="./htmlsrc/std.date.html#L284" kind="function" beg="284" end="337">MonthFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#MonthFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L284">#</a></dt>
<dd class="ddef">
<div class="summary">Calculates the month from the d_time t.</div>
<p class="sec_header">Returns:</p>Integer in the range 0..11, where
        0 represents January and 11 represents December.</dd>
<dt class="decl">int <a class="symbol _function" name="DateFromTime" href="./htmlsrc/std.date.html#L344" kind="function" beg="344" end="374">DateFromTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#DateFromTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L344">#</a></dt>
<dd class="ddef">
<div class="summary">Compute which day in a month a d_time t is.</div>
<p class="sec_header">Returns:</p>Integer in the range 1..31</dd>
<dt class="decl">int <a class="symbol _function" name="WeekDay" href="./htmlsrc/std.date.html#L382" kind="function" beg="382" end="389">WeekDay</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#WeekDay" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L382">#</a></dt>
<dd class="ddef">
<div class="summary">Compute which day of the week a d_time t is.</div>
<p class="sec_header">Returns:</p>Integer in the range 0..6, where 0 represents Sunday
        and 6 represents Saturday.</dd>
<dt class="decl">d_time <a class="symbol _function" name="UTCtoLocalTime" href="./htmlsrc/std.date.html#L395" kind="function" beg="395" end="400">UTCtoLocalTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#UTCtoLocalTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L395">#</a></dt>
<dd class="ddef">
<div class="summary">Convert from UTC to local time.</div></dd>
<dt class="decl">d_time <a class="symbol _function" name="LocalTimetoUTC" href="./htmlsrc/std.date.html#L406" kind="function" beg="406" end="414">LocalTimetoUTC</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#LocalTimetoUTC" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L406">#</a></dt>
<dd class="ddef">
<div class="summary">Convert from local time to UTC.</div></dd>
<dt class="decl">d_time <a class="symbol _function" name="MakeTime" href="./htmlsrc/std.date.html#L417" kind="function" beg="417" end="423">MakeTime</a><span class="params">(d_time <em>hour</em>, d_time <em>min</em>, d_time <em>sec</em>, d_time <em>ms</em>)</span>; <a title="Permalink to this symbol" href="#MakeTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L417">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="MakeDay" href="./htmlsrc/std.date.html#L433" kind="function" beg="433" end="455">MakeDay</a><span class="params">(d_time <em>year</em>, d_time <em>month</em>, d_time <em>date</em>)</span>; <a title="Permalink to this symbol" href="#MakeDay" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L433">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="MakeDate" href="./htmlsrc/std.date.html#L457" kind="function" beg="457" end="463">MakeDate</a><span class="params">(d_time <em>day</em>, d_time <em>time</em>)</span>; <a title="Permalink to this symbol" href="#MakeDate" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L457">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="TimeClip" href="./htmlsrc/std.date.html#L465" kind="function" beg="465" end="470">TimeClip</a><span class="params">(d_time <em>time</em>)</span>; <a title="Permalink to this symbol" href="#TimeClip" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L465">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="DateFromNthWeekdayOfMonth" href="./htmlsrc/std.date.html#L485" kind="function" beg="485" end="516">DateFromNthWeekdayOfMonth</a><span class="params">(int <em>year</em>, int <em>month</em>, int <em>weekday</em>, int <em>n</em>)</span>; <a title="Permalink to this symbol" href="#DateFromNthWeekdayOfMonth" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L485">#</a></dt>
<dd class="ddef">
<div class="summary">Determine the date in the month, 1..31, of the nth
 weekday.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>year</td></tr>
<tr><td><em>month</em></td><td>month, 1..12</td></tr>
<tr><td><em>weekday</em></td><td>day of week 0..6 representing Sunday..Saturday</td></tr>
<tr><td><em>n</em></td><td>nth occurrence of that weekday in the month, 1..5, where
            5 also means "the last occurrence in the month"</td></tr></table>
<p class="sec_header">Returns:</p>the date in the month, 1..31, of the nth weekday</dd>
<dt class="decl"><a class="symbol _unittest" name="unittest" href="./htmlsrc/std.date.html#L518" kind="unittest" beg="518" end="524">unittest</a>; <a title="Permalink to this symbol" href="#unittest" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L518">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="DaysInMonth" href="./htmlsrc/std.date.html#L532" kind="function" beg="532" end="552">DaysInMonth</a><span class="params">(int <em>year</em>, int <em>month</em>)</span>; <a title="Permalink to this symbol" href="#DaysInMonth" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L532">#</a></dt>
<dd class="ddef">
<div class="summary">Determine the number of days in a month, 1..31.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>month</em></td><td>1..12</td></tr></table></dd>
<dt class="decl"><a class="symbol _unittest" name="unittest:2" href="./htmlsrc/std.date.html#L554" kind="unittest" beg="554" end="558">unittest</a>; <a title="Permalink to this symbol" href="#unittest:2" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L554">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">string <a class="symbol _function" name="toString" href="./htmlsrc/std.date.html#L579" kind="function" beg="579" end="625">toString</a><span class="params">(d_time <em>time</em>)</span>; <a title="Permalink to this symbol" href="#toString" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L579">#</a></dt>
<dd class="ddef">
<div class="summary">Converts UTC time into a text string of the form:
 "Www Mmm dd hh:mm:ss GMT+-TZ yyyy".
 For example, "Tue Apr 02 02:04:57 GMT-0800 1996".
 If time is invalid, i.e. is d_time_nan,
 the string "Invalid date" is returned.</div>
<p class="sec_header">Example:</p><pre class="d_code">
<span class="i">d_time</span> <span class="i">lNow</span>;
<span class="k">char</span>[] <span class="i">lNowString</span>;

<span class="lc">// Grab the date and time relative to UTC</span>
<span class="i">lNow</span> = <span class="i">std</span>.<span class="i">date</span>.<span class="i">getUTCtime</span>();
<span class="lc">// Convert this into the local date and time for display.</span>
<span class="i">lNowString</span> = <span class="i">std</span>.<span class="i">date</span>.<span class="i">toString</span>(<span class="i">lNow</span>);
</pre></dd>
<dt class="decl">string <a class="symbol _function" name="toUTCString" href="./htmlsrc/std.date.html#L632" kind="function" beg="632" end="652">toUTCString</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#toUTCString" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L632">#</a></dt>
<dd class="ddef">
<div class="summary">Converts t into a text string of the form: "Www, dd Mmm yyyy hh:mm:ss UTC".
 If t is invalid, "Invalid date" is returned.</div></dd>
<dt class="decl">string <a class="symbol _function" name="toDateString" href="./htmlsrc/std.date.html#L660" kind="function" beg="660" end="688">toDateString</a><span class="params">(d_time <em>time</em>)</span>; <a title="Permalink to this symbol" href="#toDateString" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L660">#</a></dt>
<dd class="ddef">
<div class="summary">Converts the date portion of time into a text string of the form: "Www Mmm dd
 yyyy", for example, "Tue Apr 02 1996".
 If time is invalid, "Invalid date" is returned.</div></dd>
<dt class="decl">string <a class="symbol _function" name="toTimeString" href="./htmlsrc/std.date.html#L697" kind="function" beg="697" end="738">toTimeString</a><span class="params">(d_time <em>time</em>)</span>; <a title="Permalink to this symbol" href="#toTimeString" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L697">#</a></dt>
<dd class="ddef">
<div class="summary">Converts the time portion of t into a text string of the form: "hh:mm:ss
 GMT+-TZ", for example, "02:04:57 GMT-0800".
 If t is invalid, "Invalid date" is returned.
 The input must be in UTC, and the output is in local time.</div></dd>
<dt class="decl">d_time <a class="symbol _function" name="parse" href="./htmlsrc/std.date.html#L746" kind="function" beg="746" end="778">parse</a><span class="params">(string <em>s</em>)</span>; <a title="Permalink to this symbol" href="#parse" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L746">#</a></dt>
<dd class="ddef">
<div class="summary">Parses s as a textual date string, and returns it as a d_time.
 If the string is not a valid date, d_time_nan is returned.</div></dd>
<dt class="decl">static <a class="symbol _sctor" name="this" href="./htmlsrc/std.date.html#L780" kind="sctor" beg="780" end="784">this</a>(); <a title="Permalink to this symbol" href="#this" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L780">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="getUTCtime" href="./htmlsrc/std.date.html#L931" kind="function" beg="931" end="942">getUTCtime</a><span class="params">()</span>; <a title="Permalink to this symbol" href="#getUTCtime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L931">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">d_time <a class="symbol _function" name="getLocalTZA" href="./htmlsrc/std.date.html#L944" kind="function" beg="944" end="951">getLocalTZA</a><span class="params">()</span>; <a title="Permalink to this symbol" href="#getLocalTZA" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L944">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">int <a class="symbol _function" name="DaylightSavingTA" href="./htmlsrc/std.date.html#L957" kind="function" beg="957" end="1015">DaylightSavingTA</a><span class="params">(d_time <em>dt</em>)</span>; <a title="Permalink to this symbol" href="#DaylightSavingTA" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L957">#</a></dt>
<dd class="ddef"></dd>
<dt class="decl">typedef uint <a class="symbol _typedef" name="DosFileTime" href="./htmlsrc/std.date.html#L1025" kind="typedef" beg="1025" end="1025">DosFileTime</a>; <a title="Permalink to this symbol" href="#DosFileTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L1025">#</a></dt>
<dd class="ddef">
<div class="summary">Type representing the DOS file date/time format.</div></dd>
<dt class="decl">d_time <a class="symbol _function" name="toDtime" href="./htmlsrc/std.date.html#L1031" kind="function" beg="1031" end="1060">toDtime</a><span class="params">(DosFileTime <em>time</em>)</span>; <a title="Permalink to this symbol" href="#toDtime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L1031">#</a></dt>
<dd class="ddef">
<div class="summary">Convert from DOS file date/time to d_time.</div></dd>
<dt class="decl">DosFileTime <a class="symbol _function" name="toDosFileTime" href="./htmlsrc/std.date.html#L1066" kind="function" beg="1066" end="1089">toDosFileTime</a><span class="params">(d_time <em>t</em>)</span>; <a title="Permalink to this symbol" href="#toDosFileTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/std.date.html#L1066">#</a></dt>
<dd class="ddef">
<div class="summary">Convert from d_time to DOS file date/time.</div></dd></dl>
</div>
<div id="footer">
  <p>Copyright © 1999-2008 by Digital Mars ®, All Rights Reserved.</p>
  <p>Page generated by <a href="http://code.google.com/p/dil">dil</a> on Sun Dec 28 04:26:38 2008. Rendered by <a href="http://code.google.com/p/dil/wiki/Kandil">kandil</a>.</p>
</div>
</body>
</html>